3.6.24 \(\int \sqrt {a+a \sin (e+f x)} (c+d \sin (e+f x)) \, dx\) [524]

Optimal. Leaf size=62 \[ -\frac {2 a (3 c+d) \cos (e+f x)}{3 f \sqrt {a+a \sin (e+f x)}}-\frac {2 d \cos (e+f x) \sqrt {a+a \sin (e+f x)}}{3 f} \]

[Out]

-2/3*a*(3*c+d)*cos(f*x+e)/f/(a+a*sin(f*x+e))^(1/2)-2/3*d*cos(f*x+e)*(a+a*sin(f*x+e))^(1/2)/f

________________________________________________________________________________________

Rubi [A]
time = 0.04, antiderivative size = 62, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {2830, 2725} \begin {gather*} -\frac {2 a (3 c+d) \cos (e+f x)}{3 f \sqrt {a \sin (e+f x)+a}}-\frac {2 d \cos (e+f x) \sqrt {a \sin (e+f x)+a}}{3 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + a*Sin[e + f*x]]*(c + d*Sin[e + f*x]),x]

[Out]

(-2*a*(3*c + d)*Cos[e + f*x])/(3*f*Sqrt[a + a*Sin[e + f*x]]) - (2*d*Cos[e + f*x]*Sqrt[a + a*Sin[e + f*x]])/(3*
f)

Rule 2725

Int[Sqrt[(a_) + (b_.)*sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[-2*b*(Cos[c + d*x]/(d*Sqrt[a + b*Sin[c + d*x
]])), x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rule 2830

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[(-d
)*Cos[e + f*x]*((a + b*Sin[e + f*x])^m/(f*(m + 1))), x] + Dist[(a*d*m + b*c*(m + 1))/(b*(m + 1)), Int[(a + b*S
in[e + f*x])^m, x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] &&  !LtQ[m
, -2^(-1)]

Rubi steps

\begin {align*} \int \sqrt {a+a \sin (e+f x)} (c+d \sin (e+f x)) \, dx &=-\frac {2 d \cos (e+f x) \sqrt {a+a \sin (e+f x)}}{3 f}+\frac {1}{3} (3 c+d) \int \sqrt {a+a \sin (e+f x)} \, dx\\ &=-\frac {2 a (3 c+d) \cos (e+f x)}{3 f \sqrt {a+a \sin (e+f x)}}-\frac {2 d \cos (e+f x) \sqrt {a+a \sin (e+f x)}}{3 f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.09, size = 82, normalized size = 1.32 \begin {gather*} -\frac {2 \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right ) \sqrt {a (1+\sin (e+f x))} (3 c+2 d+d \sin (e+f x))}{3 f \left (\cos \left (\frac {1}{2} (e+f x)\right )+\sin \left (\frac {1}{2} (e+f x)\right )\right )} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + a*Sin[e + f*x]]*(c + d*Sin[e + f*x]),x]

[Out]

(-2*(Cos[(e + f*x)/2] - Sin[(e + f*x)/2])*Sqrt[a*(1 + Sin[e + f*x])]*(3*c + 2*d + d*Sin[e + f*x]))/(3*f*(Cos[(
e + f*x)/2] + Sin[(e + f*x)/2]))

________________________________________________________________________________________

Maple [A]
time = 2.59, size = 58, normalized size = 0.94

method result size
default \(\frac {2 \left (1+\sin \left (f x +e \right )\right ) a \left (\sin \left (f x +e \right )-1\right ) \left (d \sin \left (f x +e \right )+3 c +2 d \right )}{3 \cos \left (f x +e \right ) \sqrt {a +a \sin \left (f x +e \right )}\, f}\) \(58\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sin(f*x+e))^(1/2)*(c+d*sin(f*x+e)),x,method=_RETURNVERBOSE)

[Out]

2/3*(1+sin(f*x+e))*a*(sin(f*x+e)-1)*(d*sin(f*x+e)+3*c+2*d)/cos(f*x+e)/(a+a*sin(f*x+e))^(1/2)/f

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2)*(c+d*sin(f*x+e)),x, algorithm="maxima")

[Out]

integrate(sqrt(a*sin(f*x + e) + a)*(d*sin(f*x + e) + c), x)

________________________________________________________________________________________

Fricas [A]
time = 0.33, size = 92, normalized size = 1.48 \begin {gather*} -\frac {2 \, {\left (d \cos \left (f x + e\right )^{2} + {\left (3 \, c + 2 \, d\right )} \cos \left (f x + e\right ) + {\left (d \cos \left (f x + e\right ) - 3 \, c - d\right )} \sin \left (f x + e\right ) + 3 \, c + d\right )} \sqrt {a \sin \left (f x + e\right ) + a}}{3 \, {\left (f \cos \left (f x + e\right ) + f \sin \left (f x + e\right ) + f\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2)*(c+d*sin(f*x+e)),x, algorithm="fricas")

[Out]

-2/3*(d*cos(f*x + e)^2 + (3*c + 2*d)*cos(f*x + e) + (d*cos(f*x + e) - 3*c - d)*sin(f*x + e) + 3*c + d)*sqrt(a*
sin(f*x + e) + a)/(f*cos(f*x + e) + f*sin(f*x + e) + f)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \sqrt {a \left (\sin {\left (e + f x \right )} + 1\right )} \left (c + d \sin {\left (e + f x \right )}\right )\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))**(1/2)*(c+d*sin(f*x+e)),x)

[Out]

Integral(sqrt(a*(sin(e + f*x) + 1))*(c + d*sin(e + f*x)), x)

________________________________________________________________________________________

Giac [A]
time = 0.52, size = 90, normalized size = 1.45 \begin {gather*} \frac {\sqrt {2} {\left (d \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) \sin \left (-\frac {3}{4} \, \pi + \frac {3}{2} \, f x + \frac {3}{2} \, e\right ) + 3 \, {\left (2 \, c \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right ) + d \mathrm {sgn}\left (\cos \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )\right )} \sin \left (-\frac {1}{4} \, \pi + \frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )} \sqrt {a}}{3 \, f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))^(1/2)*(c+d*sin(f*x+e)),x, algorithm="giac")

[Out]

1/3*sqrt(2)*(d*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e))*sin(-3/4*pi + 3/2*f*x + 3/2*e) + 3*(2*c*sgn(cos(-1/4*pi + 1
/2*f*x + 1/2*e)) + d*sgn(cos(-1/4*pi + 1/2*f*x + 1/2*e)))*sin(-1/4*pi + 1/2*f*x + 1/2*e))*sqrt(a)/f

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \int \sqrt {a+a\,\sin \left (e+f\,x\right )}\,\left (c+d\,\sin \left (e+f\,x\right )\right ) \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a*sin(e + f*x))^(1/2)*(c + d*sin(e + f*x)),x)

[Out]

int((a + a*sin(e + f*x))^(1/2)*(c + d*sin(e + f*x)), x)

________________________________________________________________________________________